package com.karst.webnotes.chapter03
{
	import flash.events.Event;
	
	import org.aswing.AsWingManager;
	import org.papervision3d.objects.primitives.Plane;
	import org.papervision3d.view.BasicView;
	
	internal class PlaneExample extends BasicView
	{
		public function PlaneExample()
		{
			super() ;
			setStage() ;
			createView() ;
			startRendering() ;
		}
		
		private function setStage() : void
		{
			AsWingManager.getStage().frameRate = 40 ;  //设置帧频
		}
		
		private var plane : Plane  = null ; // 平面
		private function createView() : void
		{
			if( plane == null )
				plane = new Plane( null, 300, 300, 1, 1 ) ;
			scene.addChild( plane ) ;
		}
		
		override protected function onRenderTick( event : Event = null ) : void
		{
			super.onRenderTick() ;
		}
	}
}